package com.itheim.mapper;

import com.itheim.pojo.Student;
import com.itheim.pojo.StudentQueryParem;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Mapper;

import java.time.LocalDateTime;
import java.util.List;
import java.util.Map;

@Mapper
public interface StudentMapper {
    List<Student> page(StudentQueryParem studentQueryParem);

    void addstudent(Student student);

    Student getById(Integer id);

    void update(Student student);

    void delete(Integer[] ids);

    void violationHandle(Integer id, Integer score, LocalDateTime updateTime);

    @MapKey("name")
    List<Map<String, Object>> getStudentCountData();

    @MapKey("name")
    List<Map<String, Object>> getStudentDegreeData();
}
